Method and apparatus for protecting legitimate traffic from dos and ddos attacks

ABSTRACT

An apparatus for protecting legitimate traffic from DoS and DDoS attacks has a high-priority ( 505 ) and a low-priority ( 506 ) queue. Besides, a queue information table ( 402 ) has STT (Source-based Traffic Trunk) service queue information of a specific packet. A queue coordinator ( 502 ) updates the queue information table ( 502 ) based on a load of a provided STT and a load of the high-priority queue ( 505 ). A packet classifier ( 504 ) receives a packet from the network access unit ( 508 ), investigates an STT service queue of the packet from the queue information table ( 502 ), selectively transfers the packet to the high-priority ( 505 ) or the low-priority ( 506 ) queue and provides information on the packet to the queue coordinator ( 503 ). A buffer ( 507 ) buffers outputs of the high-priority ( 505 ) and the low-priority ( 506 ) queue and provides outputs to the network ( 509 ) to be protected.

FIELD OF THE INVENTION

The present invention relates to a method and apparatus for protectinglegitimate traffic from denial of service (hereinafter, referred to asDoS) and distributed denial of service (hereinafter, referred to asDDoS) attacks; and, more particularly, to a method and apparatus forprotecting the legitimate traffic from an enormous traffic volumegenerated by the DoS and DDoS attacks.

BACKGROUND OF THE INVENTION

A DoS attack concentrates large volume of traffic on a targetnetwork/server in a short time so that the target system is not able toprovide services. A DDoS attack, which is one type of DoS attack,concentrates traffic of multitude of attacking sites on the targetnetwork/server at once, and therefore, it is more difficult to detectand cut off.

According to attacking method, the DoS attacks are categorized intoattacks using characteristics of a TCP protocol and attacks for simplycongesting traffic.

Attacks using the characteristics of a TCP protocol are performed as athree-step operation of setting up a connection between a TCP client anda TCP server. First of all, the client sends a synchronous (SYN) packetto the server. Secondly, the server sends a synchronous acknowledge(SYN-ACK) packet to the client. As a final step, the client sends theACK packet to the server. A TCP SYN flooding attack is an example ofsuch attack, which keeps sending the SYN packet to the server butignores the SYN-ACK packet transmitted by the server.

Attacks for simply congesting traffic are divided into a UDP packetflooding attack, a ping flooding attack and a HTTP flooding attack.

Conventional techniques for cutting off such DoS attacks are describedas follows:

-   -   (1) a technique for improving an algorithm of a TCP protocol        server    -   (2) a fair-queuing technique    -   (3) a rate-limit technique

The technique for improving the algorithm of the TCP protocol server isrestrictively used for cutting off conventional SYN packet floodingattacks, so that it is not able to avoid traffic congestion attacks.

The fair-queuing technique is used for controlling congestion and fairlydistributing resources (bandwidth) in a router.

FIG. 1 is a drawing for showing a basic algorithm of a conventionalfair-queuing. Each of transmitted packets is separated on a flow basisand sent to a next node by using a corresponding queue. In this case,queues are fairly distributed by using a round-robin service, so thateach queue is provided with 1/n of a total link bandwidth. While thetechnique is able to effectively cut off DoS attacks, DDoS attacks arenot completely avoidable. That is to say, the more increase the totalnumber of malicious flows, the more decrease the bandwidth shareallocated to legitimate flows.

The rate-limit technique cuts off not only TCP SYN flooding attacks butalso traffic congestion attacks.

FIG. 2 illustrates a basic algorithm of a conventional rate-limit. Therate-limit technique measures a bandwidth of specific flows. Then, ifthe measured value exceeds a maximum allowable bandwidth determined byan administrator, surplus packets are dropped. The technique has twodrawbacks. First, the administrator is required to check traffic of anetwork for a certain time in order to determine the maximum allowablebandwidth. Second, it is difficult to effectively cut off DDoS attacks.A power of the DDoS attacks is due to enormous traffic generated byconcentrating multitude of attacking sites on one target network/server,and therefore, a volume of traffic generated by each attack site is notconsiderable. In other words, since there is only a little differencebetween volumes of traffic generated by an attacking site and alegitimate site in the DDoS attacks, it is very difficult to determinethe maximum allowable bandwidth. For example, if the maximum allowablebandwidth is set low, both DDoS traffic and legitimate traffic can becut off.

As described above, the conventional techniques are effectively used tocut off the DoS attacks but not the DDoS attacks. Further, even if theDDoS attacks can be cut off, the legitimate traffic cannot be protected.

SUMMARY OF THE INVENTION

It is, therefore, an object of the present invention to provide a methodand apparatus for protecting legitimate traffic from DoS and DDoSattacks.

In accordance with the present invention, there is provided an apparatusconnected between a network access unit and a network to be protected,for protecting legitimate traffic from DoS and DDoS attacks, including:a high-priority queue; a low-priority queue; a queue information tablehaving specific STT service queue information of a specific packet; aqueue coordinator for updating the queue information table based on aload of a provided STT and a load of the high-priority queue; a packetclassifier for receiving a packet from the network access unit,investigating an STT service queue of the received packet from the queueinformation table, selectively transferring the received packet to thehigh-priority queue or the low-priority queue in accordance with aninvestigation result and providing information on the received packet tothe queue coordinator; and a buffer for buffering outputs of thehigh-priority queue and the low-priority queue and providing thebuffered outputs to the network to be protected.

BRIEF DESCRIPTION OF THE DRAWINGS

The above and other objects and features of the present invention willbecome apparent from the following description of preferred embodiments,given in conjunction with the accompanying drawings, in which:

FIG. 1 shows a basic algorithm of a conventional fair-queuing;

FIG. 2 illustrates a basic algorithm of a conventional rate-limit;

FIG. 3 provides a drawing for showing a typical DDoS attacks modeling;

FIG. 4 presents a drawing for illustrating a DDoS attacks modelingemploying a source-based traffic trunk (STT) in accordance with thepresent invention;

FIG. 5 represents a block diagram for showing a preferred embodiment ofan apparatus for protecting legitimate traffic from DoS and DDoS attacksin accordance with the present invention;

FIG. 6 offers a flowchart for illustrating a basic algorithm of a packetclassifier shown in FIG. 5;

FIG. 7 sets forth a flowchart for showing a basic algorithm of a queuecoordinator shown in FIG. 5;

FIG. 8A depicts a flowchart of a detailed algorithm of steps forreceiving packet information and calculating an average load of an STTcorresponding to a received packet in the basic algorithm of the queuecoordinator shown in FIG. 7;

FIG. 8B shows a flowchart of an algorithm of a step for resetting an STTservice queue based on the load of the STT in the basic algorithm of thequeue coordinator illustrated in FIG. 7;

FIG. 8C provides a flowchart of an algorithm of a step for calculatingan average load of a high-priority queue in the basic algorithm of thequeue coordinator illustrated in FIG. 7;

FIG. 8D provides a flowchart of an algorithm of a step for resetting anSTT service queue based on the load of the high priority queue in thebasic algorithm of the queue coordinator shown in FIG. 7;

FIG. 9A presents a drawing for representing a simulation result ofemploying the conventional fair-queuing against web server attacks usingDoS and DDoS; and

FIG. 9B represents a drawing for showing a simulation result ofemploying a traffic control technique in accordance with the presentinvention against web server attacks using the DoS and DDoS.

DETAILED DESCRIPTION OF THE PREFERRED EMBODIMENTS

Hereinafter, preferred embodiments of the present invention will bedescribed in detail with reference to the accompanying drawings.

A flow-unit-processing of DoS and DDoS traffic causes a performance andattack-detection accuracy to be deteriorated and its load to beincreased. On the contrary, the present invention processes the DoS andDDoS traffic in a source-based traffic trunk (hereinafter, referred toas STT) unit, wherein the STT refers to a set of flows having a samenetwork address of a source. For instance, if the STT is composed of24-bit out of 32-bit IP address, every packet using source addressesfrom 168.188.44.0 to 168.188.44.255 belongs to the STT having a sourceaddress of 168.188.44.

FIG. 3 provides a drawing for showing a typical DDoS attacks modeling.FIG. 4 presents a drawing for illustrating a DDoS attacks modelingemploying a source-based traffic trunk (STT) in accordance with thepresent invention.

Sources of DDoS attacks are not uniformly distributed in entirenetworks, but centralized on certain local networks. Thus, it isimpossible for a hacker to perform a hacking on systems in every networkin the world to install DDoS attack software therein. Instead, a hackerusually intrudes a certain local network. Further, for example, even ifthe hacker intrudes an arbitrary system using a Nimda virus and performsDDoS attacks, it is still difficult for the virus to hide in a safenetwork, i.e., a network installed with a firewall, an intrusiondetection system, a virus vaccine application and the like, for acertain time. Accordingly, the virus is normally hidden in a lessprotected network. A cyber demonstration, which is a type of DDoSattacks, is also performed in certain local networks.

In comparison with a flow-typed method, the STT-typed method is able tomore simply and accurately determine whether traffic is legitimate ornot.

FIG. 5 represents a block diagram for showing a preferred embodiment ofan apparatus for protecting legitimate traffic from DoS and DDoS attacksin accordance with the present invention. A legitimate trafficprotection unit 501 comprises a queue information table 502, a queuecoordinator 503, a packet classifier 504, a high-priority queue 505, alow-priority queue 506 and a buffer 507, wherein the legitimate trafficprotection unit 501 is connected between a network access unit 508 and anetwork/server 509 to be protected.

When a packet is received from the network access unit 508, the packetclassifier 504 investigates an STT service queue of the packet from thequeue information table 502. According to the investigation result, thepacket is transferred to the high-priority queue 505 or the low-priorityqueue 506. Further, information on the packet is transferred to thequeue coordinator 503, wherein the information on the packet refers to apacket size, a packet arrival time and an index of the queue informationtable 502 for representing STT information of the packet and the like.

The queue coordinator 503 updates the queue information table 502 basedon a load of the received STT and a load of the high-priority queue 505.The queue information table 502 has fields including an STT ID, aservice queue, an average load, a recent load calculation time and atotal packet size.

A maximum load of both the high-priority queue 505 and the low-priorityqueue 506 is set to be a maximum allowable load of the network/server509 to be protected. For example, in case the maximum allowable load ofto-be-protected system is set to 100, a sum of total loads of both thehigh-priority queue 505 and the low-priority queue 506 should be set to100. If both the high-priority queue 505 and the low-priority queue 506have packets, a packet in the high-priority queue 505 is firstly served.

The buffer 507 buffers outputs of the high-priority queue 505 and thelow-priority queue 506 and sends the buffered outputs to thenetwork/server 509 to be protected.

FIG. 6 offers a flowchart for illustrating a basic algorithm of thepacket classifier 504 shown in FIG. 5.

The packet classifier 504 receives a packet from the network access unit508 (step 601) and then obtains an STT ID by using a source IP addressof the received packet (step 602). Next, the packet classifier 504searches for a service queue corresponding to the obtained STT ID fromthe queue information table 502 (step 603). According to theinvestigation result, the packet classifier 504 selectively transfersthe received packet to the high-priority queue 505 and the low-priorityqueue 506 (steps 604 to 606). Thereafter, the packet classifier 504transfers packet information to the queue coordinator 503.

FIG. 7 sets forth a flowchart for showing a basic algorithm of a queuecoordinator shown in FIG. 5.

The queue coordinator 503 receives packet information from the packetclassifier 504 (step 702) and calculates an average STT loadcorresponding to the received packet (step 703). Based on the calculatedaverage STT load, the queue coordinator 503 resets an STT service queue(step 704). Next, the queue coordinator 503 calculates an average loadof the high-priority queue 505 (step 705) and then resets a certain STTservice queue based on the calculated average load of the high-priorityqueue 505 (step 706). Thereafter, the queue coordinator 503 storesmodified STT information such as a modified average load and servicequeue in the queue information table 502 (step 707).

FIG. 8A depicts a flowchart of a detailed algorithm of steps forreceiving packet information (step 702) and calculating an average loadof an STT corresponding to a received packet (step 703) in the basicalgorithm of the queue coordinator 503 shown in FIG. 7.

The queue coordinator 503 receives packet information on a packet size,a packet arrival time, a queue information table index, a correspondingSTT and the like from the packet classifier (step 802) and thencalculates a total packet size based on the received packet information(step 803), wherein the total packet size is a sum of a previous totalpacket size and a received packet size. Next, the queue coordinator 503checks whether it is time to recalculate an average load (step 804).According to the check result, if it is time to recalculate the averageload, the queue coordinator 503 calculates a new average load by using aprevious average load and a current average load based on the totalpacket size (step 805). In other words, the average load is calculatedas follows: average load=(previous average load*α+total packetsize)/((packet arrival time−recent load calculation time)*(1−a)),wherein a is larger than 0 but smaller than 1, i.e., 0<a<1. In thiscase, a time cycle for calculating the load is predetermined by a user.According to the check result of the step 804, if it is not the time torecalculate the average load, the queue coordinator 503 executes an STTservice queue determination algorithm using the STT load value (step806) without performing the step 805.

FIG. 8B shows a flowchart of an algorithm of a step for resetting an STTservice queue based on the load of the STT (step 704) in the basicalgorithm of the queue coordinator 503 illustrated in FIG. 7. Thealgorithm in FIG. 8 b is carried out whenever a packet is arrived. Apurpose of the algorithm is to make an STT of a high average load usethe low-priority queue 506 and an STT of a low average load use thehigh-priority queue 505. Accordingly, DoS and DDoS traffic are supposedto use the low-priority queue.

The queue coordinator 503 checks whether or not the high-priority queue505 is in a congested state (step 808). According to the check result,if the high-priority queue 505 is in a congested state, it is checkedwhether an STT load of a received packet is greater than an allowableload (step 809). According to the check result of the step 809, if theSTT load of the received packet is greater than the allowable load, aservice queue of the STT of the received packet is set to be thelow-priority queue 506 (step 810), wherein the allowable load refers to“(an average load of the high-priority queue 505)/(the number of STTusing the high-priority queue 505 during a recalculation of the averageload)”. Thus, a plurality of STT that may correspond to DDoS traffic issupposed to concentrate on the low-priority queue 506 rapidly. The queuecoordinator 503 checks whether the service queue of the STTcorresponding to the received packet is a high-priority queue or alow-priority queue (step 811). According to the check result of the step811, if the service queue of the STT corresponding to the receivedpacket is a high-priority queue, an STT using a low-priority queue israndomly chosen from the queue information table 502 (step 812). Next,the queue coordinator 503 compares an average load of the STTcorresponding to the received packet with an average load of therandomly chosen STT (step 813). According to the comparison result, ifthe average load of the STT corresponding to the received packet isgreater than that of the randomly chosen STT, a queue of an STT having alow load is set to high-priority and that of an STT having a high loadis set to low-priority (step 814). According to the check result of thestep 811, if the service queue of the STT corresponding to the receivedpacket is a low-priority queue, an STT using a high-priority queue israndomly chosen from the queue information table 502 (step 815). Thequeue coordinator compares an average load of the STT corresponding tothe received packet with that of the randomly chosen STT (step 816).According to the comparison result, if the average load of the STTcorresponding to the received packet is smaller than that that of therandomly chosen STT, a queue of an STT having a low load is set tohigh-priority and that of an STT having a high load is set tolow-priority (step 817). Accordingly, legitimate traffic and the DDoStraffic are respectively supposed to use a high-priority queue and alow-priority queue.

FIG. 8C provides a flowchart of an algorithm of a step for calculatingan average load of the high-priority queue 505 (step 705) in the basicalgorithm of the queue coordinator 503 illustrated in FIG. 7. Suchalgorithm is only carried out when a service queue of a received packetis a high-priority queue.

The queue coordinator 503 determines an STT service queue on the basisof an STT load (step 819) and then checks whether the service queue usedby the received packet is a high-priority queue or a low-priority queue(step 820). As a result of the step 820, if the service queue used bythe received packet is a high-priority queue, a total size of packetsserved through the high-priority queue is calculated (step 821). Next,the queue coordinator 503 checks whether it is time to recalculate aload (step 822). According to the check result, if it is time torecalculate the load, an average load of the high-priority queue iscalculated (step 823). Then, the queue coordinator 503 resets a certainSTT service queue on the basis of the load of the high-priority queue(step 824), to thereby store modified STT information in the queueinformation table 502 (step 825).

FIG. 8D provides a flowchart of an algorithm of a step for resetting anSTT service queue based on the load of the high priority queue (step706) in the basic algorithm of the queue coordinator 503 shown in FIG.7, wherein the algorithm is executed whenever the average load of thehigh-priority queue is calculated.

The queue coordinator 503 calculates the average load of thehigh-priority queue (step 826) and checks a load state of thehigh-priority queue, e.g., a congested state, an idle state or a stablestate (step 827). If the load of the high-priority queue is in thecongested state, an STT using the high-priority queue is randomly chosenand a queue of the STT is set to low-priority (steps 828 and 829).Meanwhile, if the load thereof is in the idle state, an STT using alow-priority queue is randomly chosen and a queue of the STT is set tohigh-priority (steps 830 and 831). If the load thereof is in the stablestate or the steps 829 to 831 have already been performed, modified STTinformation is stored in the queue information table 502 (step 832). Asa result, the high-priority queue is able to maintain a stable loadthereof. Further, STT using the high-priority queue, i.e., legitimatetraffic, can be of high quality.

FIG. 9A presents a drawing for representing a simulation result ofemploying the conventional fair-queuing against web server attacks usingDoS and DDoS. FIG. 9B represents a drawing for showing a simulationresult of employing a traffic control technique in accordance with thepresent invention against web server attacks using the DoS and DDoS.

In prior arts, legitimate traffic is influenced by both the DoS and DDoSattacks as shown in FIG. 9A. However, both the DoS and DDoS attackshardly have influence on the legitimate traffic in the present inventionas illustrated in FIG. 9B.

The present invention checks traffic on an STT basis instead of on aflow basis, so that a load can be more accurately measured withoutinfluencing on a performance of an apparatus. Whenever a packet of anSTT is received, it is checked whether the specific STT is DDoS trafficor legitimate traffic. Accordingly, the DDoS traffic is quickly set to alow-priority queue as shown in 8 b. Although traffic is dramaticallyincreased due to the DDoS attacks, a load of a high-priority queue usedby legitimate traffic is constantly maintained. As a result, a loss ofthe legitimate traffic can be minimized as illustrated in FIG. 8 b to 8d. The present invention has an additional merit that even when aconsiderable traffic is generated by a specific system, if there issufficient network resource to accept it, the traffic can be servedthrough high-priority queue.

While the invention has been shown and described with respect to thepreferred embodiments, it will be understood by those skilled in the artthat various changes and modifications may be made without departingfrom the spirit and scope of the invention as defined in the followingclaims.

1. An apparatus connected between a network access unit and a network tobe protected, for protecting legitimate traffic from DoS and DDoSattacks, comprising: a high-priority queue; a low-priority queue; aqueue information table having specific STT service queue information ofa specific packet; a queue coordinator for updating the queueinformation table based on a load of a provided STT and a load of thehigh-priority queue; a packet classifier for receiving a packet from thenetwork access unit, investigating an STT service queue of the receivedpacket from the queue information table, selectively transferring thereceived packet to the high-priority queue or the low-priority queue inaccordance with an investigation result and providing information on thereceived packet to the queue coordinator; and a buffer for bufferingoutputs of the high-priority queue and the low-priority queue andproviding buffered outputs to the network to be protected.
 2. Theapparatus of claim 1, wherein the network to be protected comprises aserver.
 3. The apparatus of claim 1, wherein the information on thereceived packet includes a packet size, a packet arrival time and anindex of the queue information table for representing STT information ofthe packet.
 4. The apparatus of claim 1, wherein the queue informationtable has fields including an STT ID, a service queue, an average load,a recent load calculation time and a total packet size.
 5. The apparatusof claim 1, wherein a maximum load of the high-priority queue and thelow-priority queue is set to be a maximum allowable load of the networkto be protected.
 6. The apparatus of claim 5, wherein the network to beprotected comprises a server.
 7. A method for protecting legitimatetraffic from DoS and DDoS attacks in an apparatus therefor, wherein theapparatus is connected between a network access unit and a network to beprotected and includes a queue information table having specific STTservice queue information of a specific packet, a queue coordinator forupdating the queue information table based on a load of a provided STTand a load of a high-priority queue and a packet classifier forreceiving a packet from the network access unit, investigating an STTservice queue of a received packet from the queue information table,selectively transferring the received packet to the high-priority queueor the low-priority queue in accordance with an investigation result andproviding information on the received packet to the queue coordinator,the method comprising the steps of: (a) obtaining an STT ID based on asource IP address of the packet received from the network access unit;(b) investigating a service queue corresponding to the searched STT IDfrom the queue information table and checking whether the service queueis the high-priority queue or the low-priority queue; (c) transferringthe received packet to the high-priority queue if the service queue isthe high-priority queue in the step (b); (d) transferring the receivedpacket to the low-priority queue if the service queue is thelow-priority queue in the step (b); and (e) transferring the receivedpacket information to the queue coordinator.
 8. The method of claim 7,wherein the network to be protected comprises a server.
 9. The method ofclaim 7, wherein the queue coordinator comprises the steps of: (a′)calculating an average load of an STT corresponding to the packetinformation transferred from the packet classifier; (b′) resetting anSTT service queue based on the calculated average load of the STT; (c′)calculating an average load of the high-priority queue; (d′) resetting acertain STT service queue based on the calculated average load of thehigh-priority queue; and (e′) storing the reset STT information in thequeue information table.
 10. The method of claim 9, wherein the modifiedSTT information refers to a modified average load and service queue. 11.The method of claim 9, wherein the step (a′) further includes the stepsof: (a′1) calculating a total packet size based on the packetinformation transferred from the packet classifier; (a′2) checkingwhether it is time to recalculate an average load; (a′3) calculating anew average load by using a previous average load and a current averageload based on the total packet size if it is time to recalculate theaverage load in the step (a′2); and (a′4) performing an STT servicequeue determination algorithm based on the load of the STT if it is nottime to recalculate the average load or subsequent to executing the step(a′3).
 12. The method of claim 11, wherein the packet informationincludes a packet size, a packet arrival time, a queue information tableindex and a corresponding STT.
 13. The method of claim 9, wherein thestep (b′) further includes the steps of: (b′1) setting an STT servicequeue of a received packet to be a the low-priority queue if an STT loadof the received packet is greater than an allowable load when thehigh-priority queue is in a congested state; (b′2) randomly choosing oneSTT using a low-priority queue from the queue information table if theservice queue of the STT corresponding to the received packet is ahigh-priority queue; (b′3) setting an STT service queue of a low load tobe a high-priority queue and an STT service queue of a high load to be alow-priority queue if an average load of an STT corresponding to thereceived packet is greater than that of the randomly chosen STT; (b′4)randomly choosing one STT using a high-priority queue from the queueinformation table if the service queue of the STT corresponding to thereceived packet is a low-priority queue; and (b′5) setting an STTservice queue of a low load to be a high-priority queue and the STTservice queue of a high load to be a low-priority queue if an averageload of an STT corresponding to the received packet is smaller than thatof the randomly chosen STT.
 14. The method of claim 9, wherein the step(c′) further includes the steps of: (c′1) determining an STT servicequeue based on a load of an STT; (c′2) calculating a total packet sizeserved through a high-priority queue if the service queue used by thereceived packet is a high-priority queue; (c′3) calculating an averageload of a high-priority queue if it is time to recalculate a load; (c′4)resetting a certain STT service queue based on the load of thehigh-priority queue; and (c′5) storing modified STT information in thequeue information table.
 15. The method of claim 9, wherein the step(d′) includes the steps of: (d′1) calculating an average load of ahigh-priority queue; (d′2) randomly choosing one STT using ahigh-priority queue and setting a queue of the STT to low-priority ifthe load of the high-priority queue is in a congested state; (d′3)randomly choosing one STT using a low-priority queue and setting a queueof the STT to high-priority if the load of the high-priority queue is inan idle state; and (d′4) storing modified STT information in the queueinformation table if the load of the high-priority queue is in a stablestate or the steps of (d′2) and (d′3) are performed.